﻿using System;
using System.Collections.Generic;
using Smart.Model;
using Smart.Business.ExerciseCalculation;

namespace Smart.Service
{
    public class ExerciseCalculation : IExercise
    {
        public List<ExerciseCategory> GetAllCategories()
        {
            ExerciseBL ebl = new ExerciseBL();
            return ebl.GetAllCategories();
        }

        public List<Exercise> GetAllExercises()
        {
            ExerciseBL ebl = new ExerciseBL();
            return ebl.GetAllExercises();
        }

        public Exercise GetExerciseById(int ExId)
        {
            ExerciseBL ebl = new ExerciseBL();
            return ebl.GetExerciseById(ExId);
        }

        public List<Exercise> GetExercisesByCategory(int cat)
        {
            ExerciseBL ebl = new ExerciseBL();
            return ebl.GetExercisesByCategory(cat);
        }

        public double CalculateBurnedCalories(int ExId, int duration)
        {
            ExerciseBL ebl = new ExerciseBL();
            return ebl.CalculateBurnedCalories(ExId, duration);
        }

        public void RecordExercise(int userId, int ExId, int _duration)
        {
            ExerciseBL ebl = new ExerciseBL();
            ebl.RecordExercise(userId, ExId, _duration);
        }

    }
}
